home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
NeXTSTEP 3.1 (Developer) [x86]
/
NeXT Step 3.1 Intel dev.cdr.dmg
/
NextDeveloper
/
Examples
/
AppKit
/
Draw
/
graphicsUndo.subproj
/
LockGraphicsChange.m
< prev
next >
Wrap
Text File
|
1992-02-09
|
994b
|
50 lines
#import "drawundo.h"
@interface LockGraphicsChange(PrivateMethods)
- redoDetails;
@end
@implementation LockGraphicsChange
- (const char *)changeName
{
return NXLocalStringFromTable("Operations", "Lock", NULL, "The operation of locking down all selected graphics so that they can't be edited in anyway until they are unlocked.");
}
- undoChange
{
[graphics makeObjectsPerform:@selector(unlock)];
[graphics makeObjectsPerform:@selector(select)];
[graphicView resetLockedFlag];
[graphicView getSelection];
return [super undoChange];
}
- changeDetailClass
{
return nil;
}
- redoDetails
{
int i, count;
List *selectedGraphics;
id graphic;
selectedGraphics = [graphicView selectedGraphics];
count = [graphics count];
for (i = 0; i < count; i++) {
graphic = [graphics objectAt:i];
[graphic lock];
[graphic deselect];
[selectedGraphics removeObject:graphic];
}
[graphicView resetLockedFlag];
return self;
}
@end